\textbf{Steiner Tree Problem - STP}
\newline
For the Steiner Tree Problem STP, we want to minimize the summed edge weight over all subtrees which span all terminal nodes $t \in T$ and are allowed to use additional Steiner nodes $v \in V \setminus T$. We reformulate the graph into a directed graph by replacing each edge $e=\{i,j\} \in E$ with two arcs $a_1=(i,j),a_2=(j,i) \in A$. The weight of the undirected edge is transferred to both arcs and we will use the edge weight variables $w_{ij}$ in conjunction with arcs. In the STP we know that each terminal needs to be in  the solution and therefore can choose any terminal node $r \in T$ as root node. There is no need for an artificial root node. We will also use node variables $z_i$, where $z_i$ is 1 iff node $i$ is selected. The function $\delta^-(S)$/$\delta^-(s)$ denotes all edges from a node in $V \setminus S$ to a node in $S$/all ingoing edges of node $s$. The graph of the input instance is defined by its vertex and undirected edge sets V and E, $G=(V,E)$.

The IP is
\begin{align}
\min \quad \sum_{(i,j) \in A} y_{ij}w_{ij} & \\
\sum_{(i,j) \in \delta^-(S)} y_{ij} & \geq z_k & \forall S \subseteq V \setminus \left\{ r \right\},\forall k \in S \label{eq:stpdc} \\
z_v & = \sum_{(i,v) \in \delta^-(v)} y_{iv} & \forall v \in V \setminus \left\{ r \right\} \label{eq:stpnode} \\
z_t & = 1 & \forall t \in T \label{eq:stpterminal} \\
\sum_{(i,r)\in \delta^-(r)}y_{ir} & = 0 \label{eq:stproot} \\
y_{ij}+y_{ji} & \leq 1 & \forall \{i,j\} \in E \label{eq:stparc} \\
\end{align}

with the variables
\begin{align}
y_{ij} & \in \{ 0,1 \} & \forall (i,j) \in A \\
z_i & \in \{ 0,1 \} & \forall i \in V \setminus \{r\}
\end{align}

Equation~\eqref{eq:stpdc} is the directed cutset formulation for the STP. We do not consider all nodes anymore as in the given formulation in the slides, but create constraints for each possible set and node of the set. If for any node $z_k=0$ holds than the constraint is inactive. If for any node $z_k \in S: z_k=1$ then our directed cutset constraint is active and therefore it must hold for the whole set. This constraint ensures that the solution is connected.
\newline
\newline
A constraint for linking the node variables $z_i$ to their incoming edges is given with equation~\eqref{eq:stpnode}. Each node has exactly one incoming arc if and only if node $i$ is part of the solution. Since connectedness is already given, this also ensures there are no cycles, as then at least one node would have two incoming arcs.
\newline
\newline
Our constraint~\eqref{eq:stpterminal} is the Steiner tree problem requirement that each terminal has to be in the solution.
\newline
\newline
As we do not use an artificial root node but simply select one of the terminal nodes as root node, we have to ensure with equation~\eqref{eq:stproot} that the tree node has no incoming edges. It would of course also be possible to simply not generate incoming arc variables for the selected root node.
\newline
\newline
Finally constraint~\eqref{eq:stparc} ensures that at most one arc per undirected edge is selected.
\newline
\newline
\textbf{Collecting Steiner Tree Problem - PCSTP}
\newline
For the price collecting Steiner tree problem we can not fix our root node, therefore we will introduce an artificial root node with edges to all other nodes. We will allow only one outgoing edge from the root node, that will select the real root of the subtree. The weight of all arcs from the root node is zero. We want to maximize the profit of a spanning tree over any subset $S \subseteq V$ where each edge has a cost $w_{ij}$. The same transformation into an directed graph as for the STP is used.
\newline
\newline
The IP is:
\begin{align}
\max \quad \sum_{i \in V}z_i p_i - \sum_{(i,j)\in A}y_{ij}w_{ij} & \\
\sum_{(i,j) \in \delta^-(S)} y_{ij} & \geq z_k & \forall S \subset V \setminus \left\{ r \right\},\forall k \in S \label{eq:pcstpdc} \\
z_v & = \sum_{(i,v) \in \delta^-(v)} y_{iv} & \forall v \in V \setminus \left\{ r \right\} \label{eq:pcstpnode} \\
\sum_{(r,j) \in \delta^+(r)} y_{rj} & = 1 \label{eq:pcstproot} \\
y_{ij}+y_{ji} & \leq 1 & \forall \{i,j\} \in E \label{eq:pcstparc}
\end{align}

with the variables
\begin{align}
y_{ij} & \in \{ 0,1 \} & \forall (i,j) \in A \cup \{(r,i) : i \in V \} \\
z_i & \in \{ 0,1 \} & \forall i \in V
\end{align}

Comparing STP and PCSTP our objective function has changed and we remove the requirement of terminal nodes. Besides that we can reuse most of our constraints from the STP. Equation~\eqref{eq:pcstproot} also replaces the root node arc constraint from the STP. Instead of limiting the incoming arcs for the root node to zero, we set the number of outgoing arcs from the root to one.